home *** CD-ROM | disk | FTP | other *** search
- #ifndef _SPROCKET_UTILITYCLASSES_
- #define _SPROCKET_UTILITYCLASSES_
-
- #ifndef __QUICKDRAW__
- #include <Quickdraw.h>
- #endif
-
- // TGraphicsContext to handle saving and restoring the QuickDraw
- // (and eventually QuickDraw GX) drawing environment.
-
- class TGraphicsContext
- {
- public:
- TGraphicsContext(GrafPtr aPort);
- ~TGraphicsContext();
- private:
- GrafPtr fOldPort;
- PenState fOldPenState;
- RgnHandle fOldClip;
- };
-
-
- // TExlusiveSection class to simplfy dealing with critical sections
- // in multi-threaded code.
-
- class TExclusiveSection
- {
- public:
- TExclusiveSection();
- ~TExclusiveSection();
- };
-
- #endif
-